package com.example.composewanandroid.ui.login

import android.annotation.SuppressLint
import android.util.Log
import androidx.compose.foundation.clickable
import androidx.compose.foundation.layout.padding
import androidx.compose.material3.Scaffold
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.runtime.LaunchedEffect
import androidx.compose.ui.Modifier
import androidx.navigation.NavHostController

@SuppressLint("UnusedMaterial3ScaffoldPaddingParameter")
@Composable
fun LoginCompose(navHostController: NavHostController){
    LaunchedEffect(Unit) {
        Log.d("wenlong", "ProjectScreen: logdin")
    }
    Scaffold{innerPadding->
        Text("login页面", modifier = Modifier.clickable {
            //返回，可以看到其实他是对我们的返回函数，做了拦截处理。
            navHostController.navigateUp()

        }.padding(innerPadding))
    }

}